]> dgit.raspbian.org Git - gnome-shell.git/commit
inputMethod: Handle IBusInputContext::forward-key-press
authorCarlos Garnacho <carlosg@gnome.org>
Fri, 29 Jun 2018 15:35:39 +0000 (17:35 +0200)
committerFlorian Müllner <florian.muellner@gmail.com>
Tue, 17 Jul 2018 23:27:24 +0000 (23:27 +0000)
commit374caade4742405a402952a894f11ced77fe1b9b
tree1cea5c9dce53ee2bb387bc25c7e515bb747b2a14
parenta5937d1d6ddb706eb4b9b2f8e65c0dd34bbbd56b
inputMethod: Handle IBusInputContext::forward-key-press

The input method may hint that certain keycodes should be pressed/released
besides the textual information in ::commit. An example is hitting space
in some IMs to commit text, where both ::commit happens, and an space is
visibly inserted. In order to handle this properly, we must honor
::forward-key-press.

In order to cater for the case that a keypress is forwarded while handling
that same keypress in a physical keyboard, check the current event being
handled and just forward it as-is if it matches. This is necessary to
prevent state from being doubly set, and the second event silenced away.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/275

Closes: #275
js/misc/inputMethod.js